from .AIAssistant import AIAssistant

class ImageGenerationAssistant(AIAssistant):
    """图片生成助手类，专门用于处理图片生成相关任务"""
    
    def __init__(self, id, name, version, online, score, resolution, style_count):
        super().__init__(id, name, "图片生成助手", version, online, score)
        self._resolution = resolution
        self._style_count = style_count
    
    # Getter和Setter方法
    @property
    def resolution(self):
        return self._resolution
    
    @resolution.setter
    def resolution(self, resolution):
        self._resolution = resolution
    
    @property
    def style_count(self):
        return self._style_count
    
    @style_count.setter
    def style_count(self, style_count):
        self._style_count = style_count
    
    def process_task(self, task_content):
        """处理图片生成任务"""
        print(f"正在为【{self.name}】分配图片生成任务：{task_content}")
        
        # 模拟图片生成处理过程
        self.status_message = f"图片生成完成：{task_content}（分辨率：{self._resolution})"
        print(f"✅ {self.status_message}")
        return True
    
    def display_info(self):
        """显示助手的详细信息"""
        super().display_info()
        print(f"   支持的分辨率: {self._resolution}")
        print(f"   支持的风格数量: {self._style_count}")